package com.neusoft.service.impl;

import com.neusoft.mapper.ProductMapper;
import com.neusoft.po.Product;
import com.neusoft.service.ProductService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ProductServiceImpl implements ProductService {

    @Autowired
    private ProductMapper productMapper;

    @Override
    public List<Product> getAllProducts() {
        return productMapper.getAllProducts();
    }

    @Override
    public Product getProductById(Integer productId) {
        return productMapper.getProductById(productId);
    }
}